New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
mamba/venom: increase kernel partition size #3852
mamba/venom: increase kernel partition size #3852
Conversation
Please update the Signed-off-by with your full real name. |
Be aware that buildbot images will be bigger, so final numbers for kernel sizes should be acquired with buildbot settings and all feeds installed (unless you did that already, but number reported seem to low from my experience). |
@adschm
I've updated the Signed-off-by, GitHub seems to be slow.
buildbot images will be bigger
I will test this soon.
|
Building 5.4 with
yields a 3,203,306 byte kernel. Tested booting on mamba. Current OpenWrt snapshot for WRT3200ACM kernel size is 3,208,600. |
With all feeds installed? ./scripts/feeds update -a |
Just enable them in a patch, don't think you need to refer to the older ones for that.
If sysupgrade still works, yes. If reflashing is required, the version should be bumped to 2.0. |
And please do all the changes in one commit per device, i.e. adjust partitions, remove DEFAULT=n, adjust compat version. |
Done. And yes that was with feeds installed. |
So far no issues after flashing a resized image. Hopefully all goes well on the buildbots. |
Tested the latest push:
|
target/linux/mvebu/image/cortexa9.mk
Outdated
@@ -112,6 +118,7 @@ TARGET_DEVICES += linksys_wrt1900acs | |||
define Device/linksys_wrt1900ac-v1 | |||
$(call Device/linksys) | |||
$(Device/dsa-migration) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
dsa-migration can obviously be dropped now, as it's the same two variables you reset with the new include.
Please put the relevant changes directly in the first two patches; they belong together.
Well, essentially the compat_version is a property of the config; just consider swconfig vs. DSA. For backup/restore, you would have to change the uci config value manually similar to what uci-defaults does. Still, in this very case we are left with the strange situation that /etc/board.json and /etc/config/system will have different explicit version numbers stored. I will have to think about that ... |
dsa-migration can obviously be dropped now
Updated
Please put the relevant changes directly in the first two patches
To confirm, just two commits total?
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Run-tested on 2 WRT1900AC v1 (mamba). Confirmed as working.
nitroshift
@adschm |
Please use the same name as commit author and in the Signed-off-by line. It is good that you do this in separate commits for venom and mamba. |
mamba has a 3MB kernel partition as specified by the DTS. 3MB is not sufficient for building with many kernel modules or newer kernel versions. mamba uboot however as set from factory will load up to 4MB. This can be observed by looking a uboot log: NAND read: device 0 offset 0xa00000, size 0x400000 4194304 bytes read: OK and from uboot environment variables: $ fw_printenv | grep "pri_kern_size"; pri_kern_size=0x400000 Resize the root partitions from 37MB to 36MB to let kernel expand into it another 1MB. And set kernel target size to 4MB. Lastly add a compatibility version message: kernel-size-migration. And set it on mamba to prevent sysupgrading without first reinstalling from a factory image. Signed-off-by: Tad Davanzo <tad@spotco.us>
venom has a 3MB kernel partition as specified by the DTS. 3MB is not sufficient for building with many kernel modules or newer kernel versions. venom uboot however as set from factory will load up to 6MB. This can be observed by looking a uboot log: NAND read: device 0 offset 0x900000, size 0x600000 6291456 bytes read: OK and from uboot environment variables: $ fw_printenv | grep "priKernSize"; priKernSize=0x0600000 Resize the root partitions from 120MB to 117MB to let kernel expand into it another 3MB. And set kernel target size to 6MB. Lastly set the kernel-size-migration compatibility version on venom to prevent sysupgrading without first reinstalling from a factory image. Signed-off-by: Tad Davanzo <tad@spotco.us>
@hauke
I have made the changes you requested.
|
Thank you for the pull request, I pushed it to master. |
Thanks everyone for making this patch! Finally can run clean no-patch truck builds on my mamba :) |
This merge request contains four commits:
This is accomplished by shrinking their root partitions by 1MB and 3MB respectively.
3MB is not enough for building with many kernel modules included and is not enough for Linux 5.10.
Both of their uboots from factory load up to those respective values.
I have tested mamba working with a 3.2MB 5.4 kernel.
I have tested mamba working with a 3.1MB 5.10 kernel.
@anomeome has tested mamba with a 3.2MB 5.10 kernel.
@solidus1983 has tested venom with a <3MB 5.4 kernel.
Compatibility can be checked like so:
mamba:
fw_printenv | grep "pri_kern_size";
must equal 0x400000venom:
fw_printenv | grep "priKernSize";
must equal 0x0600000Flashing process:
A factory style image is necessary when flashing to or away from a resized build
force
set andkeep settings
unsetFlashing from normal OpenWrt to resized has been tested to work.
Flashing from resized OpenWrt to normal has been tested to work.
Flashing from OEM firmware to resized has been tested to work (via user report).
Flashing from resized to OEM firmware has been tested to work (via user report).
There is more information in the forum thread post:
https://forum.openwrt.org/t/increasing-mamba-and-venom-kernel-partition-to-6mb/87807